/**
 * Copyright &copy; 2015-2020 <a href="http://www.jeeplus.org/">JeePlus</a> All rights reserved.
 */
package com.jeeplus.modules.web.entity;

import org.hibernate.validator.constraints.Length;

import com.jeeplus.core.persistence.DataEntity;
import com.jeeplus.common.utils.excel.annotation.ExcelField;
import com.jeeplus.modules.sys.entity.User;

import java.util.Date;

/**
 * 用户Entity
 * @author rongjie
 * @version 2017-08-06
 */
public class WxUser extends DataEntity<WxUser> {

	private static final long serialVersionUID = 2L;
	private String userName;		// 用户昵称
	private String userUrl;		// 用户头像
	private String openid;		// openid
	private String userAddress;		// 注册地址
	private Integer maintain;

	public WxUser() {
		super();
		this.setIdType(IDTYPE_AUTO);
	}

	public WxUser(String id){
		super(id);
	}

	@Length(min=1, max=120, message="用户昵称长度必须介于 1 和 120 之间")
	@ExcelField(title="用户昵称", align=2, sort=7)
	public String getUserName() {
		return userName;
	}

	public void setUserName(String userName) {
		this.userName = userName;
	}

	@Length(min=1, max=300, message="用户头像长度必须介于 1 和 300 之间")
	@ExcelField(title="用户头像", align=2, sort=8)
	public String getUserUrl() {
		return userUrl;
	}

	public void setUserUrl(String userUrl) {
		this.userUrl = userUrl;
	}

	@ExcelField(title="openid", align=2, sort=9)
	public String getOpenid() {
		return openid;
	}

	public void setOpenid(String openid) {
		this.openid = openid;
	}

	@ExcelField(title="注册地址", align=2, sort=10)
	public String getUserAddress() {
		return userAddress;
	}

	public void setUserAddress(String userAddress) {
		this.userAddress = userAddress;
	}

	public Integer getMaintain() {
		return maintain;
	}

	public void setMaintain(Integer maintain) {
		this.maintain = maintain;
	}

	@Override
	public void preInsert() {
		super.preInsert();
	}

	@Override
	public void preUpdate() {
		super.preUpdate();
	}

	@Override
	public String getRemarks() {
		return super.getRemarks();
	}

	@Override
	public void setRemarks(String remarks) {
		super.setRemarks(remarks);
	}

	@Override
	public User getCreateBy() {
		return super.getCreateBy();
	}

	@Override
	public void setCreateBy(User createBy) {
		super.setCreateBy(createBy);
	}

	@Override
	public Date getCreateDate() {
		return super.getCreateDate();
	}

	@Override
	public void setCreateDate(Date createDate) {
		super.setCreateDate(createDate);
	}

	@Override
	public User getUpdateBy() {
		return super.getUpdateBy();
	}

	@Override
	public void setUpdateBy(User updateBy) {
		super.setUpdateBy(updateBy);
	}

	@Override
	public Date getUpdateDate() {
		return super.getUpdateDate();
	}

	@Override
	public void setUpdateDate(Date updateDate) {
		super.setUpdateDate(updateDate);
	}

	@Override
	public String getDelFlag() {
		return super.getDelFlag();
	}

	@Override
	public void setDelFlag(String delFlag) {
		super.setDelFlag(delFlag);
	}

	@Override
	public String toString() {
		return "WxUser{" +
				"userName='" + userName + '\'' +
				", userUrl='" + userUrl + '\'' +
				", openid='" + openid + '\'' +
				", userAddress='" + userAddress + '\'' +
				'}';
	}
}
